<template>
<div>
<h2>我是user界面</h2>
  <h2>{{userId}}</h2>
</div>
</template>

<script>
export default {
    name: "user",
    computed: {
        userId() {
            //$route是当前活跃状态的路由
            return this.$route.params.userId
        }
    }
}
</script>

<style>

</style>